import request from '@/utils/request'

// 查询咨询回复列表
export function listconsult(query) {
  return request({
    url: '/business/consult/list',
    method: 'post',
    data: query
  })
}

// 查询咨询回复详细
export function getconsult(id) {
  return request({
    url: '/business/consult/' + id,
    method: 'get'
  })
}

// 新增咨询回复
export function addconsult(data) {
  return request({
    url: '/business/consult',
    method: 'post',
    data: data
  })
}

// 修改咨询回复
export function updateconsult(data) {
  return request({
    url: '/business/consult',
    method: 'put',
    data: data
  })
}

// 删除咨询回复
export function delconsult(id) {
  return request({
    url: '/business/consult/' + id,
    method: 'delete'
  })
}

// 导出咨询回复
export function exportconsult(query) {
  return request({
    url: '/business/consult/export',
    method: 'get',
    params: query
  })
}

//查询未回复的消息条数
export function getUndo(query){
  return request(
    {
      url:'/business/consult/getUndo',
      method:'get',
      params:query
    }
  )
}